package Cafezam;

public class J15Cal {
	private int a;
	private int b;
	
	public void setValue( int a, int b ) {
		this.a = a;
		this.b = b;
	}
	public int calculate() {
		return 0;
	}
	public int getA() { return a; }
	public int getB() { return b; 	}
} // class

class J15Add extends J15Cal {
	public int calculate() { 
		return getA() + getB(); 
	};
}	// 더하기
class J15Sub extends J15Cal {
	public int calculate() { 
		return getA() - getB(); 
	};
} // 빼기
class J15Mul extends J15Cal {
	public int calculate() { 
		return getA() * getB(); 
	};
} // 곱하기
class J15Div extends J15Cal {
	public int calculate() { 
		return getA() / getB(); 
	};
} // 나누기







